Fix non-native full screen show menu with notch, and changing resolution #1450
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently MacVim's "show menu bar" option for non-native full screen does not work properly on newer MacBook's with a notch, as macOS's API for menu bar height for some reason does not return the full height of the menu bar (it only returns the height of the "normal" menu bar). We need to manually use visibleArea instead but that API also has an issue where it's for some reason 1 pixel less, meaning you see a black bar at the top, so we have to hack it to add 1 pixel. This is really not ideal and hopefully Apple fixes it with a new API.
Also fix it so changing resolution when MacVim is in non-native full screen will work properly.
When working on this, identified an issue that the dock detection logic doesn't really work, as we don't really know if the current screen has the dock visible or not due to lack of API to query it. Just left a comment for future reference.